<template>
  <div class="existing wd1200">
    <el-row class="list-box" :gutter="20">
      <el-col v-for="(item, index) in list" :key="'l' + index" :span="12">
        <div class="classify" @click="toUrl(item)">
          <div>
            <img :src="require(`@/assets/images/busNeighbors/open/${index}.png`)" alt="">
            <span>{{ item.title }}</span>
          </div>
          <div>
            <span v-loading="loading" class="color-o" style="text-align: end;display: inline-block;min-width: 80px">{{ count1[index] }}家</span>
            <img src="../../../../assets/images/busNeighbors/r.png" alt="" class="right-icon">
          </div>
        </div>
      </el-col>
    </el-row>
    <v-title color="#FF8C1A" background-color="#FFF3E8" title="创新企业" class="title" />
    <el-row class="list-box" :gutter="20">
      <el-col v-for="(item,index) in list1" :key="'s' + index" :span="item.span">
        <div class="classify" @click="toUrl(item)">
          <div>
            <img :src="require(`@/assets/images/busNeighbors/open/0${index%9}.png`)" alt="">
            <span>{{ item.title }}</span>
          </div>
          <div>
            <span v-loading="loading1" class="color-o" style="text-align: end;display: inline-block;min-width: 80px">{{ count2[index] || 0 }}家</span>
            <img src="../../../../assets/images/busNeighbors/r.png" alt="" class="right-icon">
          </div>
        </div>
      </el-col>
    </el-row>
  </div>
</template>
<script>
import vTitle from '@/components/busNeighbors/title'
import { build_company_employment_count, build_cx_intellectual_property, build_company_cx_count, company_cx_type_count } from '@/api/busNeighbors'
export default {
  name: 'Existing',
  components: {
    vTitle
  },
  data() {
    return {
      list: [{
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '招聘企业数',
        num: '2000家',
        api: 'build_company_employment_com_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'build_company_employment_sustain_capital_range',
          params: {
            companyMajorType: 3,
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'build_company_employment_sustain_capital_range_count',
          params: {
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id),
          startDate: this.$dayjs().startOf('month').format('YYYY-MM-DD')
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '知识产权拥有企业',
        num: '2000家',
        api: 'cx_intellectual_property_page',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'cx_intellectual_property_capital_range',
          params: {
            companyMajorType: 3,
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            lyComType: 5,
            lyId: Number(this.$route.query.id)
          }
        }, {
          api: 'cx_intellectual_property_establish_range',
          exProperty: 'establishRange',
          params: {
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            lyComType: 5,
            lyId: Number(this.$route.query.id)
          }
        }],
        params: {
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10
        }
      }],
      list1: [{
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '创新企业总数',
        num: '2000家',
        span: 24,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            // companyLabel: '创新企业总数',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            // companyLabel: '创新企业总数',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          // companyLabel: '创新企业总数',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '专精特新企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '专精特新企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '专精特新企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '专精特新企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '企业技术中心',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '企业技术中心',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '企业技术中心',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '企业技术中心',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '众创空间',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '众创空间',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '众创空间',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '众创空间',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '技术先进型服务企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '技术先进型服务企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '技术先进型服务企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '技术先进型服务企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '独角兽企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '独角兽企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '独角兽企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '独角兽企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '瞪羚企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '瞪羚企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '瞪羚企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '瞪羚企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '科技企业孵化器',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '科技企业孵化器',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '科技企业孵化器',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '科技企业孵化器',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '科技型中小企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '科技型中小企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '科技型中小企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '科技型中小企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '科技小巨人企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '科技小巨人企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '科技小巨人企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '科技小巨人企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '高新技术企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '高新技术企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '高新技术企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '高新技术企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '专精特新小巨人企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '专精特新小巨人企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '专精特新小巨人企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '专精特新小巨人企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '创新型中小企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '创新型中小企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '创新型中小企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '创新型中小企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '工程技术研究中心',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '工程技术研究中心',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '工程技术研究中心',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '工程技术研究中心',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: '隐形冠军企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '隐形冠军企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '隐形冠军企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '隐形冠军企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '税收百强企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '税收百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '税收百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '税收百强企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '内链主企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '内链主企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '内链主企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '内链主企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/1.png'),
        title: 'GDP贡献前两百强企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: 'GDP贡献前两百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: 'GDP贡献前两百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: 'GDP贡献前两百强企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '行业重点企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '行业重点企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '行业重点企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '行业重点企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '区库百强企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '区库百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '区库百强企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '区库百强企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      },
      // {
      //   icon: require('@/assets/images/busNeighbors/2.png'),
      //   title: '种子独角兽企业',
      //   num: '2000家',
      //   span: 8,
      //   api: 'company_cx_type_list',
      //   url: '/bus-neighbors/list',
      //   searchApi: [{
      //     api: 'company_cx_type_capital_range',
      //     params: {
      //       companyLabel: '种子独角兽企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }, {
      //     api: 'company_cx_type_establish_range',
      //     exProperty: 'establishRange',
      //     params: {
      //       companyLabel: '种子独角兽企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }],
      //   params: {
      //     companyLabel: '种子独角兽企业',
      //     endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //     lyComType: 5,
      //     lyId: Number(this.$route.query.id),
      //     pageNumber: 1,
      //     pageSize: 10,
      //     shpId: Number(this.$route.query.id)
      //   }
      // },
      // {
      //   icon: require('@/assets/images/busNeighbors/2.png'),
      //   title: '省级专精特新企业',
      //   num: '2000家',
      //   span: 8,
      //   api: 'company_cx_type_list',
      //   url: '/bus-neighbors/list',
      //   searchApi: [{
      //     api: 'company_cx_type_capital_range',
      //     params: {
      //       companyLabel: '省级专精特新企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }, {
      //     api: 'company_cx_type_establish_range',
      //     exProperty: 'establishRange',
      //     params: {
      //       companyLabel: '省级专精特新企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }],
      //   params: {
      //     companyLabel: '省级专精特新企业',
      //     endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //     lyComType: 5,
      //     lyId: Number(this.$route.query.id),
      //     pageNumber: 1,
      //     pageSize: 10,
      //     shpId: Number(this.$route.query.id)
      //   }
      // },
      // {
      //   icon: require('@/assets/images/busNeighbors/2.png'),
      //   title: '未来独角兽企业',
      //   num: '2000家',
      //   span: 8,
      //   api: 'company_cx_type_list',
      //   url: '/bus-neighbors/list',
      //   searchApi: [{
      //     api: 'company_cx_type_capital_range',
      //     params: {
      //       companyLabel: '未来独角兽企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }, {
      //     api: 'company_cx_type_establish_range',
      //     exProperty: 'establishRange',
      //     params: {
      //       companyLabel: '未来独角兽企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }],
      //   params: {
      //     companyLabel: '未来独角兽企业',
      //     endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //     lyComType: 5,
      //     lyId: Number(this.$route.query.id),
      //     pageNumber: 1,
      //     pageSize: 10,
      //     shpId: Number(this.$route.query.id)
      //   }
      // },
      {
        icon: require('@/assets/images/busNeighbors/2.png'),
        title: '招商项目企业',
        num: '2000家',
        span: 8,
        api: 'company_cx_type_list',
        url: '/bus-neighbors/list',
        searchApi: [{
          api: 'company_cx_type_capital_range',
          params: {
            companyLabel: '招商项目企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }, {
          api: 'company_cx_type_establish_range',
          exProperty: 'establishRange',
          params: {
            companyLabel: '招商项目企业',
            endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
            shpId: Number(this.$route.query.id)
          }
        }],
        params: {
          companyLabel: '招商项目企业',
          endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
          lyComType: 5,
          lyId: Number(this.$route.query.id),
          pageNumber: 1,
          pageSize: 10,
          shpId: Number(this.$route.query.id)
        }
      }
      // {
      //   icon: require('@/assets/images/busNeighbors/2.png'),
      //   title: '规下样本企业',
      //   num: '2000家',
      //   span: 8,
      //   api: 'company_cx_type_list',
      //   url: '/bus-neighbors/list',
      //   searchApi: [{
      //     api: 'company_cx_type_capital_range',
      //     params: {
      //       companyLabel: '规下样本企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }, {
      //     api: 'company_cx_type_establish_range',
      //     exProperty: 'establishRange',
      //     params: {
      //       companyLabel: '规下样本企业',
      //       endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //       shpId: Number(this.$route.query.id)
      //     }
      //   }],
      //   params: {
      //     companyLabel: '规下样本企业',
      //     endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
      //     lyComType: 5,
      //     lyId: Number(this.$route.query.id),
      //     pageNumber: 1,
      //     pageSize: 10,
      //     shpId: Number(this.$route.query.id)
      //   }
      // }
      ],
      count1: [],
      count2: [],
      loading: true,
      loading1: true
    }
  },
  async mounted() {
    const companyLabel = '专精特新企业,企业技术中心,众创空间,技术先进型服务企业,独角兽企业,瞪羚企业,科技企业孵化器,科技型中小企业,科技小巨人企业,高新技术企业,专精特新小巨人企业,创新型中小企业,工程技术研究中心,隐形冠军企业,税收百强企业,内链主企业,GDP贡献前两百企业,行业重点企业,区库百强企业,招商项目企业'
    Promise.all([
      await build_company_employment_count({
        endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
        shpId: Number(this.$route.query.id)
      }),
      await build_cx_intellectual_property({
        endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
        lyId: Number(this.$route.query.id)
      })
    ]).then((res) => {
      this.loading = false
      this.count1 = res.map((item) => item.data && item.data.content[0].total || 0)
    })
    Promise.all([
      await build_company_cx_count({
        endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
        shpId: Number(this.$route.query.id)
      }),
      await company_cx_type_count({
        companyLabel: companyLabel,
        endDate: this.$dayjs().endOf('month').format('YYYY-MM-DD'),
        lyId: Number(this.$route.query.id),
        shpId: Number(this.$route.query.id)
      })
    ]).then(res => {
      this.loading1 = false
      this.$set(this.count2, 0, res[0].data.content[0].total)

      companyLabel.split(',').forEach((val, i) => {
        res[1].data.content.forEach((item, index) => {
          if (item.companyLabel === val) {
            this.$set(this.count2, i + 1, item.total)
          }
        })
      })
    })
  },
  methods: {
    formatter(item) {
      return this.count2.length && this.count2.find(i => i.companyLabel === item.companyLabel) && this.count2.find(i => i.companyLabel === item.companyLabel)['total'] || 0
    },
    toUrl(item) {
      this.$router.push({ path: item.url, query: { data: JSON.stringify(item), companyNames: this.$route.query.name }})
    }
  }
}
</script>
    <style lang="scss" scoped>
    .existing {
      .list-box{
        width: 100%;
        padding-left: 20px;
      }
      .title{
        margin: 0 20px 20px 20px;
        width: calc(100% - 40px);
      }
      .classify{
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 0 10px 10px;
        background: #FFFFFF;
        border-radius: 6px 6px 6px 6px;
        border: 1px solid #E8EAEC;
        margin-bottom: 20px;
        .right-icon{
          width: 14px;
          height: 14px;
        }
        img{
          width: 24px;
          height: 24px;
          margin-right: 10px;
        }
        div{
          display: flex;
          align-items: center;
          font-size: 13px;
          color: #000000;
        }
        .color-o {
          color: #FF8C1A;
        }
      }
      .con{
        width: 100%;
        border: 1px solid #E8EAEC;
        margin-bottom: 20px;
        // height: 300px;
        .m-tit{
          padding-left: 26px;
          font-weight: 700;
          font-family: PingFang SC, PingFang SC;
        }
      }
    }
    </style>
